package com.deyuanyun.pic.ae.enumeration;

/**
 * “周边环境” 导出枚举
 *
 * @author huanglw
 * @date  2016-11-10
 *
 * History: [修改人][时间][修改描述]
 */
public enum AEExportEnum {

    AEPipeLine("aePipeLine", "第三方管道及设施.xls", "ae_pipe_line.xls", -1),
    TrafficFacilities("trafficFacilities", "交通设施.xls", "traffic_facilities.xls", -1),
    SpecificPlace("specificPlace", "特定场所.xlsx", "specific_place.xlsx", 1),
    Sewer("sewer", "管道沿线地下排水排污设施.xls", "sewer.xls", 3),
    GeologicHazard("geologicHazard", "管道沿线地质灾害信息.xlsx", "geologic_hazard.xlsx", 2),
    EmergencyResource("emergencyResource", "管道沿线应急资源.xlsx", "emergency_resource.xlsx", 2),
    DifficultyRepair("difficultyRepair", "难以维修接近.xls", "difficulty_repair.xls", 2),
    PressObject("pressObject", "管道占压.xlsx", "press_object.xlsx", 2),
    PopulationDistribution("populationDistribution", "管道沿线人口分布.xlsx", "population_distribution.xlsx", 2),
    ;

    private String type;
    private String fileName;
    private String tempPath;
    private Integer beginRow;

    private AEExportEnum(String type, String fileName, String tempPath, Integer beginRow) {
        this.type = type;
        this.fileName = fileName;
        this.tempPath = tempPath;
        this.beginRow = beginRow;
    }

    public String getType() {
        return type;
    }

    public String getFileName() {
        return fileName;
    }

    public String getTempPath() {
        return tempPath;
    }

    public Integer getBeginRow() {
        return beginRow;
    }

    public static AEExportEnum getEnum(String type) {
        AEExportEnum[] rs = AEExportEnum.values();
        for(int i=0,end=rs.length;i<end;i++) {
            if(rs[i].getType().equals(type)) {
                return rs[i];
            }
        }
        return null;
    }
}
